package main;

import java.util.ArrayList;
import java.util.List;

import classifier.Classifier;
import classifier.ClassifierFactory;

public class BiasedClassifierMain {

	public void proceed(String [] args) {
		String classifierType = args[0];
		String trainFile = args[1];
		String testFile = args[2];
		String resultFile = args[3];
		
		Classifier classifier = ClassifierFactory.getClassifier(classifierType);
		
		List<String> sub = new ArrayList<String>(args.length - 4);
		for(int i = 4; i < args.length; i++) {
			sub.add(args[i]);
		}
		
		classifier.train(trainFile, sub);
		classifier.test(testFile, resultFile);
	}
	
	public static void main(String[] args) {
		BiasedClassifierMain m = new BiasedClassifierMain();
		m.proceed(args);
	}

}
